package Ex1;

public class Ex04_Q4 {

	public static void main(String[] args) {

		System.out
				.println("                           Multiplication Table        ");
		System.out
				.println("           1       2       3       4       5       6       7       8       9");
		System.out
				.println("-----------------------------------------------------------------------------");
		// System.out.println("1  |       1       2       3       4       5       6       7       8       9");
		/*
		 * for(int i=1; i<=9; i++){
		 * 
		 * if(i==1)System.out.print(i+"  |");
		 * 
		 * System.out.print("       "+i); } System.out.println(); for(int i=1;
		 * i<=9; i++){ if(i==1)System.out.print((2*i)+"  |");
		 * System.out.print("       "+2*i); } System.out.println(); for(int i=1;
		 * i<=9; i++){ if(i==1)System.out.print((3*i)+"  |");
		 * System.out.print("       "+3*i); } System.out.println(); for(int i=1;
		 * i<=9; i++){ if(i==1)System.out.print((4*i)+"  |");
		 * System.out.print("       "+4*i); } System.out.println(); for(int i=1;
		 * i<=9; i++){ if(i==1)System.out.print((5*i)+"  |");
		 * System.out.print("       "+5*i); } System.out.println(); for(int i=1;
		 * i<=9; i++){ if(i==1)System.out.print((6*i)+"  |");
		 * System.out.print("       "+6*i); } System.out.println(); for(int i=1;
		 * i<=9; i++){ if(i==1)System.out.print((7*i)+"  |");
		 * System.out.print("       "+7*i); } System.out.println(); for(int i=1;
		 * i<=9; i++){ if(i==1)System.out.print((8*i)+"  |");
		 * System.out.print("       "+8*i); } System.out.println(); for(int i=1;
		 * i<=9; i++){ if(i==1)System.out.print((9*i)+"  |");
		 * System.out.print("       "+9*i); }
		 */

		System.out.println();
		
	for(int j=1; j<=9; j++){
		for (int i = 1; i <= 9; i++) {
			
			if (i == 1)
			System.out.print((i * j) + "  |");
			System.out.print("\t" + i * j);
			
		}
		System.out.println();
		}
	}

}
